<?php
defined('BY_JYA') or exit('error');
$_RQ['op']=$_RQ['op']?$_RQ['op']:'basic';
$return=array();
if($_RQ['op']=='basic'){
	if($_RQ['postdata']){
		$postdata=get_postdata();
		$this->plugin_setting('setting',$postdata);
		exi('设置成功');
	}
	$footernav =array(
		array('title'=>'首页','icon'=>'icon-shouye','action'=>'jy_kuaijiefee/index/'),
		array('title'=>'商家中心','icon'=>'icon-shouye','action'=>'jy_merch/manage.index/'),
		array('title'=>'代理中心','icon'=>'icon-shouye','action'=>'jy_merch/zhaoshang.index/'),
	);	
	$return['item']=$this->plugin_setting('setting');
	$return['item']['yao_feetype']=$return['item']['yao_feetype']?:0;
	$return['item']['footernav']=$return['item']['footernav']?:$footernav;
	$htmls=array(
		'type'=>'edit',
		'desc'=>'参数设置',
		'tabs'=>$tabs,
		'edit_tab'=>true,
		'edits'=>array(
			array(
				'title'=>'基础设置',
				'list'=>array(
					array('type'=>'tip','title'=>'[温馨提示]：商户抽成比例，请前往商户设置！'),
				)
			),
			array(
				'title'=>'底部导航',
					'list'=>array(
								array('type'=>'array','name'=>'footernav','add_tip'=>'添加一个底部导航',
									'list'=>array(
										array('type'=>'string','name'=>'title','title'=>'导航名称'),
										array('type'=>'icon','name'=>'icon','from'=>'jinyunicon','title'=>'导航图标'),
										array('type'=>'string','name'=>'action','title'=>'导航链接'),							
									),
									'details'=>array(
										array('type'=>'string','name'=>'title','title'=>'导航名称'),
										array('type'=>'icon','name'=>'icon','from'=>'jinyunicon','title'=>'导航图标','help'=>'图标，例如：icon-shouye'),							
										array('type'=>'link','name'=>'action','from'=>'action','title'=>'导航链接'),
									)
								),
					)
			),
		)
	);
	$return['htmls']=$htmls;
	exi($return);
}


